package com.zjsy.dao;

import java.util.List;

import com.zjsy.po.MainNews;
import com.zjsy.po.MainNewsList;
import com.zjsy.po.MainNewsModule;

public interface MainNewsDao {
	
	
	//添加新闻模块
	public void addNewsModule(MainNewsModule newsModule);
	
	//通过新闻模块的kind查询所有module
	public List<MainNewsModule> findNewsMoudle(String kind);
	
	//查找所有新闻
	public List<MainNewsList> findMainNews();
	
	//查找所有轮播图
	public List<MainNewsList> findShufflingNews();
	
	public MainNews findShufflingNewsById(String id);
	
	//查找新闻--分页
	public List<MainNewsList> findMainNewsByPage(int min,int max);
	
	public List<MainNewsList> findMainNewsByDetail(String firstClassify,String secondClassify,int min,int max);
	
	public List<MainNewsList> findMainNewsByDetails(String firstClassify,String secondClassify);
	
	//通过id查找新闻模块
	public MainNewsModule findNewsMoudleById(String id);
	                   
	public void updateNewByid(MainNewsModule newsModule);
	
	public void updateNewsByid(MainNews news);
	
	public void updateShufllingNewsByid(MainNews news);
	
	public void deleteNewsByid(String id);
	
	public void addNews(MainNews mainNews);
	
	public MainNews findMainNewsById(String id);

}
